/**
 * Created by abdulazizalonizi on 7/16/17.
 */
import java.util.Scanner ;
public class task5 {
    public static void main (String [] args)
    {
        Scanner kb = new Scanner(System.in);

        System.out.println("enter a string");
        String s1 = kb.nextLine();

        System.out.println("enter to integer indexes");
        int in1 = kb.nextInt();
        int in2 = kb.nextInt();

        String letter1 = s1.substring(in1,in1+1);
        String letter2 = s1.substring(in2,in2+1);

        String s2 = s1.substring(0,in1) + letter2 + s1.substring(in1+1 , in2) +letter1 + s1.substring(in2+1);

        System.out.println(s2);








    }
}
